<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>

<style type="text/css">
	body{
		background-color:#AAEEFF;
	}
	#center{	
		margin:180px;	
		text-align:center;
	}
	.table1{
		font-size:14px;
		
		border-top-color:#FF0000;
	}
	.button1{
		background:#FFFFDD;
		font-weight:bold;
		width:70px;
	}
</style>
<script type="text/javascript">
	function addInfo(){
		window.location.href="insertStudentScore.jsp";
	}
	function goBack(){
		window.location.href="success.jsp";
	}
</script>

</head>
<body >
	<div id="center">
	<h3>学生基本信息表</h3>	
	<table align="center" width="600"  border="0" cellpadding="0" cellspacing="0" class="table1">
	<tr>
		<td>学号</td><td>课程号</td><td>姓名</td><td>课程名</td><td>成绩</td><td>操作</td><td>操作</td>
	</tr>
	<c:forEach items="${info}" var="s">
	<tr>
		<td>${s.studentID }</td>
		<td>${s.sourceInfoEntity.sourceID }</td>
		<td>${s.studentName }</td>
		<td>${s.sourceInfoEntity.sourceName }</td>
		<td>${s.scoreInfoEntity.score }</td>
		<td><a href="studentServlet?action=SelectStudentInfoById&studentID=${s.studentID}&sourceID=${s.sourceInfoEntity.sourceID}"><input type="button" value="修改"></a></td>
		<td><a href="studentServlet?action=DeleteStudentInfoById&studentID=${s.studentID}&sourceID=${s.sourceInfoEntity.sourceID}"><input type="button" value="删除"></a></td>
	</tr>
	
	</c:forEach>
		
	</table>
	<br>	
	<input type="submit" value="添加"  class="button1" onclick="addInfo()">
	<input type="submit" value="返回" class="button1" onclick="goBack()">
	</div>
</body>
</html>